#ifndef TIMESERIESDATASET_H_INCLUDED
#define TIMESERIESDATASET_H_INCLUDED

#include <wx/xy/xyplot.h>
#include <wx/xy/xylinerenderer.h>

#include <wx/axis/numberaxis.h>
#include <wx/axis/dateaxis.h>

/**
 * Time series demo dataset.
 */
class TimeSeriesDataset : public XYDataset, public DateTimeDataset
{
	//DECLARE_CLASS(TimeSeriesDataset)
public:
	TimeSeriesDataset(double *data, time_t *times, size_t count);
	virtual ~TimeSeriesDataset();

	virtual size_t GetSerieCount();

	virtual wxString GetSerieName(size_t serie);

	virtual size_t GetCount(size_t serie);

	virtual double GetX(size_t index, size_t serie);

	virtual double GetY(size_t index, size_t serie);

	virtual DateTimeDataset *AsDateTimeDataset();

	//
	// DateTimeDataset
	//
	virtual time_t GetDate(size_t index);

	virtual size_t GetCount();


private:
	double *m_data;
	time_t *m_times;
	size_t m_count;
};
#endif // TIMESERIESDATASET_H_INCLUDED
